/*
 * @Author: your name
 * @Date: 2021-06-29 15:17:28
 * @LastEditTime: 2021-07-01 10:27:40
 * @LastEditors: Please set LastEditors
 * @Description: cookie操作
 * @FilePath: \briup\day15\mobile-app\src\utils\auth.js
 */
import Cookies from 'js-cookie'
import { tokenKey } from './config'

// 设置token
export function setToken(token) {
    // 给cookie里存值，key-value形式
    Cookies.set(tokenKey, token);
}
// 获取token
export function getToken() {
    return Cookies.get(tokenKey);
}
// 移除token
export function removeToken() {
    Cookies.remove(tokenKey);
}